package com.tool_stdy.thread;

import java.io.File;

/**
 * Created by yan_li on 2016/1/16.
 */
public class DiGuiFileTest {
    public static void main(String[] args) {
        FileDo(new File("F:\\tt"),0);
    }

    public static void FileDo(File f,int j) {
        File[] files = f.listFiles();
        for (File fs : files) {
            for(int i=0;i<j;i++){
                System.out.print("  ");
            }
            System.out.println(fs.getName());
            if (fs.isDirectory()) {
                j++;
                FileDo(fs,j);
            }
        }
    }
}
